<template>
  <!-- 轮播 -->
  <div class="carousel-container" style="width: 100%; height: 585px;">
    <el-carousel :indicator="'circle'" height="580px">
      <el-carousel-item v-for="item in list" :key="item.banner">
        <img :src="item.banner">
      </el-carousel-item>
    </el-carousel>
  </div>
  <!-- 精选品牌 -->
  <div class="featured">
    <img src="../../../assets/精选品牌切图.png" alt="">
  </div>
</template>

<script lang= "ts" setup>
import { ref,reactive } from 'vue';
// 轮播接口
import { lunbo } from '../../../api/home';
const list = ref<any[]>([])
const lunBotu =async () => {
  const result:any = await lunbo()
  console.log('轮播',result);
  list.value = result.swiper
}
lunBotu()

</script>

<style lang= "less" scoped>
.el-carousel__indicators.is-circle .el-carousel__indicator{
  display: block;
  border-radius: 50%;
}
.el-carousel__item img {
  width: 100%;
  height: 580px;
  object-fit: cover;
}
.featured{
  width: 1000px;
  height: 655px;
  margin: 80px auto 0;
  img{
    width: 100%;
    height: 100%;
  }
}
</style>
